package com.edu.study.base.lmsOrderReturnApply.service.impl;

import com.edu.study.base.lmsOrderReturnApply.domain.LmsOrderReturnApply;
import com.edu.study.base.lmsOrderReturnApply.mapper.LmsOrderReturnApplyMapper;
import com.edu.study.base.lmsOrderReturnApply.service.ILmsOrderReturnApplyService;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * LmsOrderReturnApplyService业务层处理
 * 
 * @author zw
 * @date 2021-08-11
 */
@Service
//@DataSource(value = DataSourceType.SLAVE)
public class LmsOrderReturnApplyServiceImpl implements ILmsOrderReturnApplyService 
{
    @Autowired
    private LmsOrderReturnApplyMapper lmsOrderReturnApplyMapper;

    /**
     * 查询LmsOrderReturnApply
     * 
     * @param id LmsOrderReturnApplyID
     * @return LmsOrderReturnApply
     */
    @Override
    public LmsOrderReturnApply selectLmsOrderReturnApplyById(Long id)
    {
        return lmsOrderReturnApplyMapper.selectLmsOrderReturnApplyById(id);
    }

    /**
     * 查询LmsOrderReturnApply列表
     * 
     * @param lmsOrderReturnApply LmsOrderReturnApply
     * @return LmsOrderReturnApply
     */
    @Override
    public List<LmsOrderReturnApply> selectLmsOrderReturnApplyList(LmsOrderReturnApply lmsOrderReturnApply)
    {
        return lmsOrderReturnApplyMapper.selectLmsOrderReturnApplyList(lmsOrderReturnApply);
    }

    /**
     * 新增LmsOrderReturnApply
     * 
     * @param lmsOrderReturnApply LmsOrderReturnApply
     * @return 结果
     */
    @Override
    public int insertLmsOrderReturnApply(LmsOrderReturnApply lmsOrderReturnApply)
    {
        lmsOrderReturnApply.setCreateTime(DateUtils.getNowDate());
        return lmsOrderReturnApplyMapper.insertLmsOrderReturnApply(lmsOrderReturnApply);
    }

    /**
     * 修改LmsOrderReturnApply
     * 
     * @param lmsOrderReturnApply LmsOrderReturnApply
     * @return 结果
     */
    @Override
    public int updateLmsOrderReturnApply(LmsOrderReturnApply lmsOrderReturnApply)
    {
        return lmsOrderReturnApplyMapper.updateLmsOrderReturnApply(lmsOrderReturnApply);
    }

    /**
     * 批量删除LmsOrderReturnApply
     * 
     * @param ids 需要删除的LmsOrderReturnApplyID
     * @return 结果
     */
    @Override
    public int deleteLmsOrderReturnApplyByIds(Long[] ids)
    {
        return lmsOrderReturnApplyMapper.deleteLmsOrderReturnApplyByIds(ids);
    }

    /**
     * 删除LmsOrderReturnApply信息
     * 
     * @param id LmsOrderReturnApplyID
     * @return 结果
     */
    @Override
    public int deleteLmsOrderReturnApplyById(Long id)
    {
        return lmsOrderReturnApplyMapper.deleteLmsOrderReturnApplyById(id);
    }
}
